(HSP3) sample7 [LogCheck].hsp

sample\hspdsc\(HSP3) sample7 [LogCheck].hsp » Plain Format

#include "hspdsc.as"

	title "ログの表示"
	
	dsc_Init
	
	// エラー発生時、通知するウィンドウハンドルを指定
	dsc_SetErrorCallbackHwnd hwnd, 0x8765
	oncmd gosub *e ,0x8765

	sdim log, 4096*10
	dsc_SetLogLevel 2	// 全ログ出力
	dsc_SetLogBuffer log, 4096*10
	
	// 何か実行する
	sdim devlist, 4096
	dsc_GetDeviceList devlist, 0

	// ログ表示
	mesbox log, 640, 480, 0
	
stop

*e
	// エラーがあったとき飛んできます
	notesel devlist
	noteget tmp, notemax-1
	dialog tmp
return